package com.nbcio.demo.domain.bo;

import com.nbcio.demo.domain.TestOrderGoods;
import com.nbcio.common.mybatis.core.domain.BaseEntity;
import com.nbcio.common.core.validate.AddGroup;
import com.nbcio.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;
import java.math.BigDecimal;
import java.util.List;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * 订单子表对象 test_order_goods
 *
 * @author nbacheng
 * @date 2025-04-24
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = TestOrderGoods.class, reverseConvertGenerate = false)
public class TestOrderGoodsBo extends BaseEntity {

            /**
             * 商品编码
             */
                @NotBlank(message = "商品编码不能为空" , groups = { AddGroup.class, EditGroup.class })
            private String goodCode;

            /**
             * 商品名字
             */
                @NotBlank(message = "商品名字不能为空" , groups = { AddGroup.class, EditGroup.class })
            private String goodName;

            /**
             * 价格
             */
                @NotNull(message = "价格不能为空" , groups = { AddGroup.class, EditGroup.class })
            private BigDecimal price;

            /**
             * 数量
             */
                @NotNull(message = "数量不能为空" , groups = { AddGroup.class, EditGroup.class })
            private Long num;

            /**
             * 单品总价
             */
                @NotNull(message = "单品总价不能为空" , groups = { AddGroup.class, EditGroup.class })
            private BigDecimal zongPrice;

            /**
             * 订单ID
             */
                @NotNull(message = "订单ID不能为空" , groups = { AddGroup.class, EditGroup.class })
            private Long mainId;


}
